<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title></title>
	</head>
	<body>
		
		<script type="text/javascript">
			// 声明若干类来表示生活中的例子，例如：书、房子、树等等，至少5个。
			function Book(name,price,type) {
			    this.name = name;
			    this.price = price;
			    this.type = type;
			}
			let book = new Book("木偶奇遇记","25","童话书");
			console.log(book);
			
			function House(tier,type){
				this.tier = tier;	//层数
				this.type = type;	
			}
			let house = new House("5","别墅");
			console.log(house);
			
			function Car(name,price){
				this.name = name;
				this.price = price;
			}
			let car = new Car("兰博基尼","300w");
			console.log(car);
			
			function Computer(brand,price){
				this.brand = brand;
				this.price = price;
			}
			let computer = new Computer("联想","6999");
			console.log(computer);
			
			function Keyboard(brand,type,price){
				this.brand = brand;
				this.type = type;
				this.price = price;
			}
			let keyboard = new Keyboard("黑峡谷","GK715","299");
			console.log(keyboard);
		</script>
	</body>
</html>
